package main

import (
	"10-middleware/middleware"
	"log"
	"net/http"
)

// logging 安全 请求超时 响应压缩
// 黑白名单
func main() {

	http.HandleFunc("/", func(writer http.ResponseWriter, request *http.Request) {
		writer.Write([]byte("success!"))
	})

	log.Fatalln(http.ListenAndServe("localhost:8080",
		&middleware.Auth{Next: nil}))
}
